package edu.java.texbooks.scjp.collections.test06.iterator.fruit;

import edu.java.texbooks.scjp.collections.test06.iterator.fruit.FruitSort;

public class Fruit {

	// --- Instance Variables --------------------------------------------------
	String name = null;
	FruitSort sort = null;

	// --- Constructor ---------------------------------------------------------
	public Fruit(String name, FruitSort sort) {
		this.name = name;
		this.sort = sort;
	}

	// --- Getters and Setters -------------------------------------------------
	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public FruitSort getSort() {
		return sort;
	}

	public void setSort(FruitSort sort) {
		this.sort = sort;
	}

	// --- Methods -------------------------------------------------------------
	@Override
	public String toString() {
		return getName();
		// return "[ " + getName() + ", " + getSort() + " ]";
	}

}
